<?xml version="1.0" encoding="UTF-8"?>
<!-- 
    Document   : forumHome
    Created on : Jan 8, 2009, 3:48:19 AM
    Author     : starcounter
-->
<jsp:root version="2.1" xmlns:f="http://java.sun.com/jsf/core" xmlns:h="http://java.sun.com/jsf/html" xmlns:ice="http://www.icesoft.com/icefaces/component" xmlns:jsp="http://java.sun.com/JSP/Page">
    <jsp:directive.page contentType="text/html;charset=UTF-8" pageEncoding="UTF-8"/>
    <f:view>
        <ice:outputHtml id="outputHtml1">
            <ice:outputHead id="outputHead1">
                <ice:outputStyle href="./resources/stylesheet.css" id="outputStyle1"/>
                <ice:outputStyle href="./xmlhttp/css/xp/xp.css" id="outputStyle2"/>
                <ice:outputStyle href="/resources/forum.css" id="outputStyle3"/>
            </ice:outputHead>
            <ice:outputBody id="outputBody1" style="-rave-layout: grid">
                <div style="left: 0px; top: 0px; position: absolute">
                    <jsp:directive.include file="MasterPages/Header.jspf"/>
                </div>
                <div style="left: 0px; top: 96px; position: absolute">
                    <jsp:directive.include file="MasterPages/Navigator.jspf"/>
                </div>
                <div style="left: 0px; top: 800px; position: absolute">
                    <jsp:directive.include file="MasterPages/footer.jspf"/>
                </div>
                <div style="left: 0px; top: 110px; position: absolute;height: 100%; width: 100%">
                <ice:form id="form1">
                    <ice:panelGroup id="panelGroup1" style="height: 100%; width: 100%">
                        <br/>
                        <h3 align="center">Diễn đàn chính</h3>
                        <ice:panelLayout id="panelLayout1" style="width: 100%">
                            <ice:panelGroup id="main" rendered="#{auth.visit!=null}" style="margin-left:12px;">
                                <ice:outputLink id="outputLink4" value="newTopic.jsp">
                                    <ice:outputText id="outputText4" value="Gởi bài"/>
                                </ice:outputLink>
                            </ice:panelGroup>
                            
                            <ice:dataTable id="dt1" rows="10" value="#{forumHome.topicsComp}" var="item" width="97%">
                                <ice:column id="column1" style="width: 20px">
                                    <f:facet name="header">
                                        <ice:outputText id="ot1" value=""/>
                                    </f:facet>
                                    <ice:graphicImage id="gi" url="/resources/folder_new.gif"/>
                                </ice:column>
                                <ice:column id="column2" style="width: 550px">
                                    <f:facet name="header">
                                        <ice:outputText id="ot2" value="Chủ đề"/>
                                    </f:facet>
                                    <ice:outputLink value="viewTopic.jsp">
                                        <ice:outputText value="#{item.topic.title}"/>
                                        <f:param name="tid" value="#{item.topic.id}"/>
                                    </ice:outputLink>
                                </ice:column>
                                <ice:column id="column3" style="text-align: center">
                                    <f:facet name="header">
                                        <ice:outputText id="ot3" value="Trả lời"/>
                                    </f:facet>
                                    <ice:outputText value=" #{item.repliesNum}"/>
                                </ice:column>
                                <ice:column id="column4" style="text-align: center">
                                    <f:facet name="header">
                                        <ice:outputText id="ot4" value="Tác giả"/>
                                    </f:facet>
                                    <ice:outputText value=" #{item.topic.userName.userName}"/>
                                </ice:column>
                                <ice:column id="column5" style="text-align: center">
                                    <f:facet name="header">
                                        <ice:outputText id="ot5" value="Bài gởi sau cùng"/>
                                    </f:facet>
                                    <ice:outputText value="#{item.lastModified}"/>
                                    <ice:outputText value="bởi #{item.lastModifiedUser}"/>
                                </ice:column>
                            </ice:dataTable>
                            <ice:dataPaginator for="dt1" id="dp1" paginator="true" paginatorMaxPages="4" style="margin-left:400px">
                                <f:facet name="first">
                                    <ice:graphicImage style="border:none;" title="First Page" url="/resources/arrow-first.gif"/>
                                </f:facet>
                                <f:facet name="last">
                                    <ice:graphicImage style="border:none;" title="Last Page" url="/resources/arrow-last.gif"/>
                                </f:facet>
                                <f:facet name="previous">
                                    <ice:graphicImage style="border:none;" title="Previous Page" url="/resources/arrow-prev.gif"/>
                                </f:facet>
                                <f:facet name="next">
                                    <ice:graphicImage style="border:none;" title="Next Page" url="/resources/arrow-next.gif"/>
                                </f:facet>
                            </ice:dataPaginator>
                        </ice:panelLayout>
                    </ice:panelGroup>
                </ice:form>
                </div>
            </ice:outputBody>
        </ice:outputHtml>
    </f:view>
</jsp:root>
